package com.biubiushop.entity;

import com.biubiushop.util.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

@Data
@EqualsAndHashCode(callSuper=true)
@Entity
@Table(name = "user")
@org.hibernate.annotations.Table(appliesTo = "user",comment = "用户表")
public class User extends BaseEntity {
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@Column(nullable = false,columnDefinition = "varchar(16) comment '名称'")
	private String name;
	
	@Column(nullable = false,columnDefinition = "tinyint(1) DEFAULT '0' comment '性别(0--未知 ,1--男,2--女)'")
	private Integer sex;
	
	@Column(nullable = false,columnDefinition = "char(11) comment '手机号'")
	private String phone;
	
	@Column(columnDefinition = "varchar(64) comment '微信openId'")
	private String openId;
	
	@Column(columnDefinition = "varchar(64) comment '微信unionId'")
	private String unionId;

}
